{*Smarty*}
{if $items}
	<div class="tabs-titles">
		<ul class="tabs-titles">
			<li class="active"><a href="?q=articles/category/list"><span>{$lang.articles.category.list}</span></a></li>
			<li><a href="?q=articles/category/add"><span>{$lang.articles.category.add}</span></a></li>
		</ul>					
	</div>
	<div class="pages-list">
		<form action="?q=articles/category/list" method="post">
			<table class="content-list" cellpadding="0" cellspacing="0" border="0">
				{foreach from=$items item=item key=key}
					{if $key is even}
						<tr class="gray">
					{else}
						<tr>
					{/if}
						<td class="check left"><input type="checkbox" name="cat_id[{$item.id}]" class="check"/></td>
						<td class="title">
							<div class="border">
								<h4><a href="?q=articles/category/view&id={$item.id}">{$item.name}</a></h4>
							</div>
						</td>
						<td class="right">
							<p>{$item.descr|nl2br}</p>
							<ul class="post-options">
								<li><a href="#">статей (0)</a></li>
							</ul>
							<ul class="post-nav">
								<li class="up"><a href="?q=articles/article/add&cid={$item.id}">добавить статью</a></li>
								<li class="down"><a href="?q=articles/category/edit&id={$item.id}">редактировать</a></li>
								<li class="del"><a href="?q=articles/category/delete&id={$item.id}">удалить</a></li>
							</ul>
						</td>
					</tr>
				{/foreach}
				<tr class="op">
					<td class="check left"><input type="checkbox" class="check" /></td>
					<td class="title" colspan="2">
						<div class="border">
							<input type="submit" value="Удалить отмеченые" name="submit" class="submit"/>
						</div>
					</td>
				</tr>
			</table>
		</form>
	</div>
{else}
	<p>На данный момент нет ни одной категории. <span><a href="?q=articles/category/add">добавить</a></span></p>
{/if}